projects
/
gpsbabel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e648df3
)
Toss non-ascii chars when creating shortnames.
author
robertl
<robertl>
Wed, 15 Jan 2003 17:05:46 +0000
(17:05 +0000)
committer
robertl
<robertl>
Wed, 15 Jan 2003 17:05:46 +0000
(17:05 +0000)
mkshort.c
patch
|
blob
|
history
diff --git
a/mkshort.c
b/mkshort.c
index a551750d4bf13aa1ce1a4ca364401cf27f653c8c..e586af23658ae28da0f262a8e8fa1a4918e13e8c 100644
(file)
--- a/
mkshort.c
+++ b/
mkshort.c
@@
-144,12
+144,13
@@
mkshort(const char *istring)
/*
* Eliminate chars on the blacklist.
+ * Characters that aren't ASCII are never OK.
*/
tstring = xstrdup(ostring);
l = strlen (tstring);
cp = ostring;
for (i=0;i<l;i++) {
- if (strchr(badchars, tstring[i]))
+ if (strchr(badchars, tstring[i])
|| !isascii(tstring[i])
)
continue;
*cp++ = tstring[i];
}